﻿using System;

namespace Ns.Data.Entity
{
    /// <summary>
    /// Provides data for the Changing events. 
    /// </summary>
    /// <typeparam name="T">The type of the property changed.</typeparam>
    public class ChangingEventArgs<T> : EventArgs
    {
        /// <summary>
        /// Gets or sets a value that indicates whether the event handler has completely handled the event or whether the system should continue its own processing.
        /// </summary>
        /// <value>
        ///   <c>true</c> if the event has been completely handled; otherwise, <c>false</c>.
        /// </value>
        public bool Handled { get; set; }

        /// <summary>
        /// Gets or sets the result.
        /// </summary>
        /// <value>The result.</value>
        public T Result { get; set; }

        /// <summary>
        /// Initializes a new instance of the <see cref="ChangingEventArgs&lt;T&gt;"/> class.
        /// </summary>
        internal ChangingEventArgs()
        {
        }        
    }
}
